module.exports = (ctx,cookieName,cookie,exp = 30 * 60) => {
    ctx.cookies.set(
        cookieName,
        cookie,
        {
            maxAge: exp * 1000, 
            expires: new Date(new Date().getTime()+exp * 1000), 
            httpOnly: true, 
            overwrite: true 
        }
    );
}